export namespace BackendTypes {
    export interface TextEmbeddingRequest {
        apiKey: string;
        input: string;
        model: string;
    }
    export interface TextEmbeddingResponse {
        object: string;
        data: {
            embedding: number[];
            index: number;
        }[];
        model: string;
    }

    export interface ChatCompletionRequest {
        apiKey: string;
        model: string;
        messages: {
            role: "system" | "user" | "assistant";
            content: string;
        }[];
    }
    export interface ChatCompletionResponse {
        id: string;
        created: number;
        model: string;
        message: {
            role: "assistant";
            content: string;
        };
    }
}

export abstract class BaseAgentBackend {
    static async getTextEmbedding(
        request: BackendTypes.TextEmbeddingRequest
    ): Promise<BackendTypes.TextEmbeddingResponse> {
        throw new Error("Not implemented");
    }
    static async getChatCompletion(
        request: BackendTypes.ChatCompletionRequest,
        modelConfig: Record<string, any>
    ): Promise<BackendTypes.ChatCompletionResponse> {
        throw new Error("Not implemented");
    }
    static getTokenLimit(modelType: string): number {
        throw new Error("Not implemented");
    }
}
